home *** CD-ROM | disk | FTP | other *** search
/ HPAVC / HPAVC CD-ROM.iso / SWAG9708.ZIP / SUPPORT.BAT < prev    next >
DOS Batch File  |  1997-08-31  |  6KB  |  146 lines

  1. @echo off
  2.  
  3. REM  *************************************************************************
  4. REM  Edited 11-26-94, to comply with the new 3.0 reader.
  5. REM  No longer adds SWAGCOMP.EXE to SWAG.ZIP, per NEWFOR.300
  6. REM  Now adds SWAG.EXE, SWAGV.EXE to SWAG.ZIP, per NEWFOR.300
  7. REM  Also adds BXP03A.ZIP, and XX3402.ZIP to SWAG.ZIP, since these
  8. REM    were previously only available in ALLSWAGS.ZIP.
  9. REM  Also adds NEWFOR.300 to SWAG.ZIP
  10. REM  Also, copies each .DIZ to the %2 directory, so they get added.
  11. REM  Now adds ALL .TXT files to SWAG.ZIP.
  12. REM
  13. REM  Don Krause, the Squirrel's Nest BBS.
  14. REM
  15. REM  Above modifications were done, so that people that have to get SWAGs
  16. REM  in pieces, (ie: SWAG.ZIP  SWAGA-C.ZIP etc) get ALL the goodies
  17. REM  that are in ALLSWAGS.ZIP
  18. REM  *************************************************************************
  19.  
  20. REM  COMPLIMENTS TO FRANK DIACHEYSN FOR MODIFYING THIS FILE TO WORK WITH
  21. REM  ZIP AND ARJ FORMATS
  22.  
  23. REM  SUPPORT.BAT
  24. REM  Packs archive files SWAGX-Y using current .SWG files,
  25. REM  Support sites DO NOT have to download the ENTIRE SWAG files package
  26. REM  with each release.  All that is necessary is to download SWAGYYMM.ZIP
  27. REM  OR ALLSWAGS.ZIP.  SWAGYYMM.ZIP can be used to update the current copy
  28. REM  of ALLSWAGS.ZIP that the support site has.  Once this is done, the
  29. REM  smaller support archives can be created with this batch file.
  30.  
  31. REM  This makes it easy for Support sites to download ONLY the SWAG update
  32. REM  or the ALLSWAGS.ZIP and create the five supporting archives.
  33. REM
  34. REM  There are TWO varibles needed with this batch file.
  35. REM  %1 is the directory location of your SWAG ZIP files.
  36. REM  %2 is the directory location of your *.SWG files.
  37. REM  %3 [ARJ] is optional and makes support.bat use ARJ instead of PkZip
  38. REM  therefore, call this for DOS : support [swagzips] [swagfiles] [ARJ]
  39.  
  40. IF "%1" == "" GOTO SYNTAX
  41. IF "%2" == "" GOTO SYNTAX
  42. IF "%3" == "ARJ" GOTO ARJ
  43. IF "%3" == "arj" GOTO ARJ
  44.  
  45. IF EXIST %1\file_id.diz COPY %1\file_id.diz %1\support.diz
  46. REM  Create SWAG.ZIP
  47. IF EXIST %1\swag.zip DEL %1\swag.zip
  48. COPY swag.diz %2\file_id.diz
  49.  
  50. REM Modified 11-29-94
  51. REM PKZIP -ex %1\swag.zip %2\reader.exe %2\bbs.txt %2\swag.txt %2\reader.doc %2\file_id.diz %2\swagcomp.exe
  52. PKZIP -ex %1\swag.zip %2\reader.exe %2\*.txt %2\reader.doc %2\file_id.diz 
  53. PKZIP -ex %1\swag.zip %2\swag.exe %2\swagv.exe %2\bxp03a.zip %2\xx3402.zip %2\newfor.300
  54.  
  55. REM  Create SWAGA-C.ZIP
  56. IF EXIST %1\swaga-c.zip DEL %1\swaga-c.zip
  57. COPY swaga-c.diz %2\file_id.diz
  58. PKZIP -ex %1\swaga-c.zip %2\a*.swg %2\b*.swg %2\c*.swg %2\file_id.diz
  59.  
  60. REM  Create SWAGD-F.ZIP
  61. IF EXIST %1\swagd-f.zip DEL %1\swagd-f.zip
  62. COPY swagd-f.diz %2\file_id.diz
  63. PKZIP -ex %1\swagd-f.zip %2\d*.swg %2\e*.swg %2\f*.swg %2\file_id.diz
  64.  
  65. REM  Create SWAGG-M.ZIP
  66. IF EXIST %1\swagg-m.zip DEL %1\swagg-m.zip
  67. COPY swagg-m.diz %2\file_id.diz
  68. PKZIP -ex %1\swagg-m.zip %2\g*.swg %2\h*.swg %2\i*.swg %2\file_id.diz -x%2\grepswag.*
  69. PKZIP -ex %1\swagg-m.zip %2\j*.swg %2\k*.swg %2\l*.swg %2\m*.swg -x%2\grepswag.*
  70.  
  71. REM  Create SWAGN-R.ZIP
  72. IF EXIST %1\swagn-r.zip DEL %1\swagn-r.zip
  73. COPY swagn-r.diz %2\file_id.diz
  74. PKZIP -ex %1\swagn-r.zip %2\n*.swg %2\o*.swg %2\p*.swg %2\q*.swg %2\r*.swg %2\file_id.diz
  75.  
  76. REM  Create SWAGS-Z.ZIP
  77. IF EXIST %1\swags-z.zip DEL %1\swags-z.zip
  78. COPY swags-z.diz %2\file_id.diz
  79. PKZIP -ex %1\swags-z.zip %2\s*.swg %2\t*.swg %2\u*.swg %2\v*.swg %2\w*.swg
  80. PKZIP -ex %1\swags-z.zip %2\x*.swg %2\y*.swg %2\z*.swg %2\file_id.diz
  81.  
  82. REM  Create ALLSWAGS.ZIP  //Added 11-26-94
  83. IF EXIST %1\a;;swags.zip DEL %1\allswags.zip
  84. COPY allswags.diz %2\file_id.diz
  85. PKZIP -ex %1\allswags.zip %2\*.*
  86.  
  87. GOTO END
  88.  
  89. :ARJ
  90.  
  91. IF EXIST %1\file_id.diz COPY %1\file_id.diz %1\support.diz
  92. REM  Create SWAG.ARJ
  93. IF EXIST %1\swag.arj DEL %1\swag.arj
  94. COPY swag.diz %2\file_id.diz
  95.  
  96. REM  Modified 11-26-94
  97. REM  arj a %1\swag.arj %2\reader.exe %2\bbs.txt %2\swag.txt %2\reader.doc %2\file_id.diz %2\swagcomp.exe
  98. arj a %1\swag.arj %2\reader.exe %2\* %2\reader.doc %2\file_id.diz
  99. arj a %1\swag.arj %2\swag.exe %2\swagv.exe %2\bxp03a.zip %2\xx3402.zip %2\newfor.300
  100.  
  101. REM  Create SWAGA-C.arj
  102. IF EXIST %1\swaga-c.arj DEL %1\swaga-c.arj
  103. COPY swaga-c.diz %2\file_id.diz
  104. arj a %1\swaga-c.arj %2\a*.swg %2\b*.swg %2\c*.swg %2\file_id.diz
  105.  
  106. REM  Create SWAGD-F.arj
  107. IF EXIST %1\swagd-f.arj DEL %1\swagd-f.arj
  108. COPY swagd-f.diz %2\file_id.diz
  109. arj a %1\swagd-f.arj %2\d*.swg %2\e*.swg %2\f*.swg %2\file_id.diz
  110.  
  111. REM  Create SWAGG-M.arj
  112. IF EXIST %1\swagg-m.arj DEL %1\swagg-m.arj
  113. COPY swagg-m.diz %2\file_id.diz
  114. arj a %1\swagg-m.arj %2\g*.swg %2\h*.swg %2\i*.swg %2\file_id.diz -x%2\grepswag.*
  115. arj a %1\swagg-m.arj %2\j.swg %2\k*.swg %2\l*.swg %2\m*.swg -x%2\grepswag.*
  116.  
  117. REM  Create SWAGN-R.arj
  118. IF EXIST %1\swagn-r.arj DEL %1\swagn-r.arj
  119. COPY swagn-r.diz %2\file_id.diz
  120. arj a %1\swagn-r.arj %2\n*.swg %2\o*.swg %2\p*.swg %2\q*.swg %2\r*.swg %2\file_id.diz
  121.  
  122. REM  Create SWAGS-Z.arj
  123. IF EXIST %1\swags-z.arj DEL %1\swags-z.arj
  124. COPY swags-z.diz %2\file_id.diz
  125. arj a %1\swags-z.arj %2\s*.swg %2\t*.swg %2\u*.swg %2\v*.swg %2\w*.swg
  126. arj a %1\swags-z.arj %2\x*.swg %2\y*.swg %2\z*.swg %2\file_id.diz
  127.  
  128. REM  Create ALLSWAGS.arj  // Added 11-26-94
  129. IF EXIST %1\allswags.arj DEL %1\allswags.arj
  130. COPY allswags.diz %2\file_id.diz
  131. arj a %1\allswags.arj %2\*.*
  132.  
  133. GOTO END
  134.  
  135. :SYNTAX
  136. ECHO SUPPORT.BAT Create SWAG Support ZIPS from *.SWG Files
  137. ECHO Third parameter "[ARJ]" is optional and creates ARJs instead of ZIPs
  138. ECHO SYNTAX: SUPPORT [swagZIPpath] [swagFILESpath] [ARJ]
  139.  
  140. ECHO   e.g. "SUPPORT \swag\zips \swag\files"
  141.  
  142. :END
  143.  
  144. IF EXIST %1\file_id.diz DEL %1\file_id.diz
  145. IF EXIST %1\support.diz REN %1\support.diz %1\file_id.diz
  146.